#define _CRT_SECURE_NO_WARNINGS 520
#include<stdio.h>
#include<string.h>

void reverse(char* str)
{
	char* left = str;
	char* right = str;
	while (*right != '\0')
	{
		right++;
	}
	right -= 1;
	while (left < right)
	{
		char temp = *left;
		*left = *right;
		*right = temp;
		left++;
		right--;
	}
}


int main()
{
	char str[10001] = { 0 };
	char ch;
	int i = 0;
	while ((ch = getchar()) != '\n')
	{
		str[i++] = ch;
	}
	str[i] = '\0';
	reverse(str);
	printf("%s", str);
	return 0;
}